//
//  XLGCheckVersionChannelProtocol+HTTPChannelProtocol.m
//  mcrmSAAS
//
//  Created by wjxfhxy on 15-4-17.
//  Copyright (c) 2015年 GuangZhouXuanWu. All rights reserved.
//

#import "XLGCheckVersionChannelProtocol+HTTPChannelProtocol.h"

#import "XLGHTTPProtocolBase.h"

@interface CheckVersionHTTPProtocol : XLGHTTPProtocolBase

@end

@implementation CheckVersionHTTPProtocol

- (void)writeRequestProtocol:(writeRequestProtocolBlock)protocol
{
    protocol(@"api/update", XLGHTTPMethodTypeGet ,NULL,nil,nil);
}

- (void)readResponseProtocol:(NSDictionary *)jsonDictionary output:(NSObject **)obj
{
    if(jsonDictionary != nil)
    {
        XLGUpdateInfoObj* thisObj = [XLGUpdateInfoObj new];
        *obj = thisObj;
    }
}

@end

@implementation XLGCheckVersionChannelProtocol (HTTPChannelProtocol)

#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wobjc-protocol-method-implementation"

- (CProtocolBase*)checkVersionProtocol
{
    return [CheckVersionHTTPProtocol new];
}

#pragma clang diagnostic pop


@end
